#!/bin/bash
#
# gelatin-nv8.sh
# Author: Andy Chu
#
# Run gelatin under narwhal-v8

NARWHAL_ROOT=/home/andy/git/narwhal2
GELATIN_ROOT=/home/andy/git/narwhal2/packages/gelatin-js

INTERPRETER=${INTERPRETER:-./nw.sh}

# Bootstrapping issues: remove system and file

$INTERPRETER $GELATIN_ROOT/bin/gelatin \
  -o $GELATIN_ROOT/recipe-archive.js \
  -p $NARWHAL_ROOT/packages/:/home/andy/git \
  -e system,file \
  -n 'var file = require("file");' \
  -m $GELATIN_ROOT/data/narwhal-main.jsont \
  -s '/usr/bin/env narwhal' \
  "$@"
